<template>
  <div></div>
</template>

<script>
import { onMounted, onUpdated, onUnmounted } from 'vue'
export default {
  setup () {
    console.log('setup')
    // 生命周期使用方式与vue2相同
    onMounted(() => {
      console.log('mounted')
    })

    onUpdated(() => {
      console.log('update')
    })
    onUnmounted(() => {
      console.log('unmounted')
    })
  }
}
</script>

<style>

</style>
